package io;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;

public class Demo1 {
    public static void main(String[] args) throws IOException {
        /*FileOutputStream fos = new FileOutputStream("a.txt");
        fos.write(123);
        fos.close();*/
        FileOutputStream fileOutputStream = new FileOutputStream(new File("b.txt"));
       /* fileOutputStream.write(49);
        fileOutputStream.write(48);
        fileOutputStream.write(48);*/
        /*fileOutputStream.write(new byte[]{
                65,66,67,68,69
        },2,2);*/
        byte[] bytes = "fsefsfsf".getBytes();
        fileOutputStream.write(bytes);

        fileOutputStream.close();
    }
}
